import { WebTag } from './webTag';

import mdnLogo from '@/assets/images/mdn.png';
import vueLogo from '@/assets/images/logo.png';
import vantLogo from '@/assets/images/vant.png';
import iviewLogo from '@/assets/images/iview.svg';
import euiLogo from '@/assets/images/element-ui.svg';
import eplusLogo from '@/assets/images/element-plus-logo.svg';
const reactLogo =
  '';

export interface WebItem {
  label: string;
  url: string;
  img: string;
  tags: Array<WebTag>;
}

export interface WebGroup {
  label: string;
  children: Array<WebItem>;
}

export default (): Array<WebGroup> => [
  {
    label: '技术ORG',
    children: [
      {
        label: 'MDN',
        url: 'https://developer.mozilla.org/zh-CN',
        img: mdnLogo,
        tags: [2, 5],
      },
      {
        label: 'Vue',
        url: 'https://cn.vuejs.org/',
        img: vueLogo,
        tags: [2, 5],
      },
      {
        label: 'Vue3',
        url: 'https://v3.cn.vuejs.org/',
        img: vueLogo,
        tags: [2, 5],
      },
      {
        label: 'NodeJS',
        url: 'http://nodejs.cn/',
        img: 'http://img.nodejs.cn/logo.svg',
        tags: [4, 9],
      },
      {
        label: 'React',
        url: 'https://zh-hans.reactjs.org/',
        img: reactLogo,
        tags: [2, 5],
      },
      {
        label: 'Express',
        url: 'https://www.expressjs.com.cn/',
        img: 'http://img.nodejs.cn/logo.svg',
        tags: [4, 9],
      },
      {
        label: 'Webpack',
        url: 'https://webpack.js.org/',
        img: '',
        tags: [2, 5, 10],
      },
      {
        label: 'Typescript',
        url: 'https://www.tslang.cn/',
        img: '',
        tags: [2, 5, 10],
      },
      {
        label: 'V8 官网',
        url: 'https://v8.dev/',
        img: '',
        tags: [1],
      },
    ],
  },
  {
    label: '组件库UI',
    children: [
      {
        label: 'ElementUI',
        url: 'https://element.eleme.cn/#/zh-CN/',
        img: euiLogo,
        tags: [14, 6, 7],
      },
      {
        label: 'ElementPlus',
        url: 'https://element-plus.gitee.io/zh-CN/',
        img: eplusLogo,
        tags: [14, 6, 7],
      },
      {
        label: 'iView',
        url: 'http://v1.iviewui.com/docs/introduce',
        img: iviewLogo,
        tags: [14, 6, 7],
      },
      {
        label: 'ColorUI',
        url: 'http://demo.color-ui.com/',
        img: '',
        tags: [12, 7],
      },
      {
        label: 'Vant',
        url: 'https://vant-contrib.gitee.io/vant/#/zh-CN/',
        img: vantLogo,
        tags: [12, 7, 6],
      },
      {
        label: 'BootstrapUI',
        url: 'https://code.z01.com/bootstrap-vue/docs/',
        img: '',
        tags: [14, 7, 6],
      },
      {
        label: 'Vux',
        url: 'https://doc.vux.li/zh-CN/',
        img: '',
        tags: [13, 7, 6],
      },
      {
        label: 'WeUI',
        url: 'https://weui.io/',
        img: '',
        tags: [12, 7, 6],
      },
      {
        label: 'NutUI',
        url: 'https://nutui.jd.com/#/intro',
        img: '',
        tags: [12, 13, 7, 6],
      },
    ],
  },
  {
    label: '工具TOOL',
    children: [
      {
        label: 'VsCode',
        url: 'https://code.visualstudio.com/',
        img: '',
        tags: [10],
      },
      {
        label: 'Typora',
        url: 'https://www.typora.net/',
        img: '',
        tags: [10, 11],
      },
    ],
  },
  {
    label: '社区COMMUNITY',
    children: [
      {
        label: '菜鸟教程',
        url: 'https://www.runoob.com/',
        img: '',
        tags: [],
      },
    ],
  },
];
